Basic table auditor

Most of these checks can be applied to most simple MLab tables and views.

This notbook is used for prototyping. The release version is in ../scripts/inspectTable.py


In [1]:
import re
import pandas as pd
import BQhelper as bq
import inspectTable

bq.project = "mlab-sandbox"

In [5]:
# Tests, designed to be repeated
UnitTest=False
if UnitTest:
    inspectTable.UnitTestAll()

if UnitTest:
    inspectTable.inventoryTable('measurement-lab.ndt.ndt5')
if False:
    inspectTable.inspectDataSetMappings('mlab-oti.base_tables')
    inspectTable.inspectDataSetMappings('measurement-lab.ndt')
    inspectTable.inspectDataSetMappings('measurement-lab.library')
if True:
    ret=bq.getTables('mlab-oti.base_tables')
    print (ret)
#    inspectTable.inventoryTable('mlab-oti.base_tables.ndt')


[]

In [ ]:
STOP

In [ ]:
# Expensive, but what we came for
# inspectTable.inventoryDataSet('measurement-lab.ndt')

# Expensive, but what we came for
# inspectTable.inventoryDataSet('measurement-lab.library')